[logstash-input] Handle connection errors correctly#536
Open
ash-darin wants to merge 5 commits into
Open
Conversation
ash-darin
commented
Apr 14, 2026
ash-darin
commented
Apr 14, 2026
ash-darin
commented
Apr 14, 2026
ash-darin
commented
Apr 14, 2026
ash-darin
commented
Apr 14, 2026
There was a problem hiding this comment.
Pull request overview
Updates the Beats input’s Netty exception handling to better classify/handle connection reset scenarios and to log handled vs. unhandled exceptions more clearly, avoiding misleading “handled” logs followed by Netty pipeline warnings.
Changes:
- Adjusts
exceptionCaughtlogging to log “Handling exception” only for handledRejectedExecutionExceptions, and “Unhandled exception” when forwarding to Netty. - Extends noisy-exception detection to treat
SocketException: Connection resetas a connection reset case.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
ash-darin
commented
Apr 17, 2026
Author
|
Hi @robbavey , am I missing anything to move this forward? I do not know which other files changed or prerequisites should be fulfilled for this. Thank you. |
The observed "socket excetions" are/were a bug of winlogbeat 8.17.10 at least. No mention of it was discovered anywhere and the problems went away with 8.18.8 or newer versions. As it is hard to replicate (might be an artifact of virtualization) remove the special handling and only keep correcting the else if issue.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Current handling of connection errors results in a log message that the case is handled, followed by an error and stack trace because it is not handled.
This change handles this by correcting the logging to indicate when an Error is handled and when it isn't.
Here is an example of connection resets that are not handled because the are not as the expected ones, observed in the wild:
Added 07.2026: The above error is caused by winlogbeat 8.17.10. It is unclear why as I have found no reference to it anywhere and goes away with an update to > 8.18.0 Might be an artifact of virtualized machines. Removed original handling of this error from PR as it's fixed by a client upgrade.
P.S. Please backport to 8.x